<div class="row">
    <div class="col-md-12">
        <div class="card">
            <div class="card-header card-header-inverse">
                <h4 class="card-header-title">
                    系统消息
                </h4>
            </div>
            <div class="card-content table-full-width">
                <div class="toolbar">
                    <div class="container-fluid">
                        <div class="row">
                            <div class="col-xs-12 col-md-7">
                                <div class="row">
                                    <div class="col-md-3">
                                        <div class="form-group label-floating is-empty">
                                            <label class="control-label"></label>
                                            <input type="text" class="form-control form-control-sm" data-provide="datepicker" id="startDate" placeholder="开始日期">
                                        </div>
                                    </div>
                                    <div class="col-md-3">
                                        <div class="form-group label-floating is-empty">
                                            <label class="control-label"></label>
                                            <input type="text" class="form-control form-control-sm" data-provide="datepicker" id="finishDate" placeholder="结束日期">
                                        </div>
                                    </div>
                                    <div class="col-md-6 text-left">
                                        <div class="form-group label-floating is-empty" style="margin-top: 4%">
                                            <label class="control-label"></label>
                                            <button class="btn btn-primary btn-sm" data-options='{"target":"FIND"}'>
                                                <i class="fa fa-search fa-fw"></i>查 找
                                            </button>
                                            <button class="btn btn-warning btn-sm" data-options='{"target":"RESET"}'>
                                                <i class="fa fa-recycle fa-fw"></i>重 置
                                            </button>
                                        </div>
                                    </div>
                                </div>
                            </div>
                        </div>
                    </div>
                </div>
                <div class="material-datatables">
                    <table id="datatable" data-url="<?= $module['RouteURL']?>" class="table table-striped table-hover display responsive nowrap" cellspacing="0" width="100%">
                        <thead>
                        <tr class="text-danger">
<!--                            <th>消息ID</th>-->
                            <th>消息类型</th>
                            <th>消息描述</th>
                            <th>消息时间</th>
                            <th>阅读状态</th>
                            <th>操作</th>
                        </tr>
                        </thead>
                    </table>
                </div>
            </div>
        </div>
    </div>
</div>
<script type="text/javascript">
    $(function () {
        $("#datatable").createPager([
            {
            width: '20%',
            data: "typeId",
            className: "text-center",
            render: function (data, type, row, meta) {
                return data == 1 ? '提款申请' : (data == 2) ? '提点审计' : '兑换审核';
            }
        }, {
            width: '30%',
            data: "content",
            className: "text-center",
            render: function (data, type, row, meta) {
                return data;
            }
        }, {
            width: '20%',
            data: "msgDate",
            className: "text-center",
            render: function (data, type, row, meta) {
                return data;
            }
        }, {
            width: '10%',
            data: "msgStatus",
            className: "text-center",
            render: function (data, type, row, meta) {
                return data == 1 ? '已读' : '<font color="red">未读</font>';
            }
        }, {
            width: '10%',
            data: "typeId",
            className: "text-center",
            render: function (data, type, row, meta) {
                return data == 1 ? '<a href="javascript:void(0);" data-id="163" data-target="navTab" data-url="/agent/bonus-review?type=1&msgId=' + (row.msgId) + '">查阅</a>' : (data == 2) ? '<a href="javascript:void(0);" data-id="163" data-target="navTab" data-url="/agent/bonus-examine?type=2&msgId=' + (row.msgId) + '">查阅</a>' : '<a href="javascript:void(0);" data-id="200" data-target="navTab" data-url="/exchange-gold/index?type=3&msgId=' + (row.msgId) + '">查阅</a>';
            }
        }]);
    });
</script>